package com.burstly.lib.util.calendar;

import com.burstly.jackson.JsonParser;
import com.burstly.jackson.JsonProcessingException;
import com.burstly.jackson.map.DeserializationContext;
import com.burstly.jackson.map.JsonDeserializer;
import com.burstly.lib.util.LoggerExt;
import java.io.IOException;
import java.util.Date;

class Rfc3339DateDeserializer extends JsonDeserializer<Long>
{
  private static Date parseRFC3339Date(String paramString)
  {
    return Rfc3339Parser.parseDateString(paramString);
  }

  public Long deserialize(JsonParser paramJsonParser, DeserializationContext paramDeserializationContext)
    throws IOException, JsonProcessingException
  {
    try
    {
      Long localLong = Long.valueOf(parseRFC3339Date(paramJsonParser.getText()).getTime());
      return localLong;
    }
    catch (Exception localException)
    {
      LoggerExt localLoggerExt = LoggerExt.getInstance();
      Object[] arrayOfObject = new Object[1];
      arrayOfObject[0] = paramJsonParser.getText();
      localLoggerExt.logError("Rfc3339DateDeserializer", "{0} is not a valid RFC3339 date", arrayOfObject);
    }
    return null;
  }
}

/* Location:           E:\android\Toy Defense 2_dex2jar.jar
 * Qualified Name:     com.burstly.lib.util.calendar.Rfc3339DateDeserializer
 * JD-Core Version:    0.6.2
 */